local _M = {}

_M.data = {
  Stat = {
    { name = "czxid", type = "long" },
    { name = "mzxid", type = "long" },
    { name = "ctime", type = "long" },
    { name = "mtime", type = "long" },
    { name = "version", type = "int" },
    { name = "cversion", type = "int" },
    { name = "aversion", type = "int" },
    { name = "ephemeralOwner", type = "long" },
    { name = "dataLength", type = "int" },
    { name = "numChildren", type = "int" },
    { name = "pzxid", type = "long" }
  }
}

_M.Stat = {
  { name = "czxid", type = "long" },
  { name = "mzxid", type = "long" },
  { name = "ctime", type = "long" },
  { name = "mtime", type = "loFng" },
  { name = "version", type = "int" },
  { name = "cversion", type = "int" },
  { name = "aversion", type = "int" },
  { name = "ephemeralOwner", type = "long" },
  { name = "dataLength", type = "int" },
  { name = "numChildren", type = "int" },
  { name = "pzxid", type = "long" }
}

_M.protocol = {
  ConnectRequest = {
    { name = "protocolVersion", type = "int" },
    { name = "lastZxidSeen", type = "long" },
    { name = "timeOut", type = "int" },
    { name = "sessionId", type = "long" },
    { name = "passwd", type = "buffer" }
  },
  ConnectResponse = {
    { name = "protocolVersion", type = "int" },
    { name = "timeOut", type = "int" },
    { name = "sessionId", type = "long" },
    { name = "passwd", type = "buffer" }
  },
  RequestHeader = {
    { name = "xid", type = "int" },
    { name = "type", type = "int" }
  },
  ReplyHeader = {
    { name = "xid", type = "int" },
    { name = "zxid", type = "long" },
    { name = "err", type = "int" }
  },
  GetChildren2Request = {
    { name = "path", type = "ustring" },
    { name = "watch", type = "boolean" }
  },
  getChildren2Response = {
    { name = "children", type = "vector<ustring>" },
    { name = "stat", type = "data.Stat" }
  }
} -- protocol

return _M





